using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Media;
using System.Windows.Threading;

namespace Tool
{
    public class ConsoleBox
    {
        private RichTextBox rtb;
        public ConsoleBox(RichTextBox richTextBox)
        {
            this.rtb = richTextBox;
        }
        public void AssistText(string str)
        {
            Run item = new Run(str);
            Paragraph paragraph = new Paragraph();
            paragraph.Inlines.Add(item);
            paragraph.Foreground = Brushes.Gray;
            paragraph.FontSize = 11;
             this.rtb.Document.Blocks.Add(paragraph);
        }
        public void DataText(string str)
        {
            Run item = new Run(str);
            Paragraph paragraph = new Paragraph();
            paragraph.Inlines.Add(item);
            paragraph.Foreground = Brushes.Blue;
            this.rtb.Document.Blocks.Add(paragraph);
        }
        public void DataSend(string str)
        {
            Run item = new Run(str);
            Paragraph paragraph = new Paragraph();
            paragraph.Inlines.Add(item);
            paragraph.Foreground = Brushes.Green;
            this.rtb.Document.Blocks.Add(paragraph);
        }
    }
}
